package com.xjggb.cloud.service;

import com.xjggb.cloud.entity.CommonResult;
import com.xjggb.cloud.entity.Payment;
import com.xjggb.cloud.service.impl.PaymentFallBackServiceImpl;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(value = "nacos-payment-provider",fallback = PaymentFallBackServiceImpl.class)  //value微服务名称 fallback 兜底的方法类
public interface PaymentService {
    @GetMapping(value = "/payment/{id}")
    public CommonResult<Payment> show(@PathVariable("id") Long id);
}
